package com.mycompany.webapp.action;

import com.mycompany.service.InvoiceManager;
import com.opensymphony.xwork2.ActionSupport;

public class EditGridAction extends ActionSupport {
	private static final long serialVersionUID = 1L;
	private Long id;
	private String name;
	private InvoiceManager invoiceManager;

	@Override
	public String execute() throws Exception {
		invoiceManager.updateName(id, name);

		return SUCCESS;
	}

	public void setInvoiceManager(InvoiceManager invoiceManager) {
		this.invoiceManager = invoiceManager;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}
}